#! /usr/bin/python
# coding: utf-8

from Tkinter import *

root = Tk()

mbLang = Menubutton(root, text='Language')

mbLang.menu = Menu(mbLang)

for item in ['Python', 'PHP', 'CPP', 'C', 'Java', 'JavaScript']:
    mbLang.menu.add_command(label=item)

mbLang['menu'] = mbLang.menu
mbLang.pack(side=LEFT)

mbOS = Menubutton(root, text='OS')
mbOS.menu = Menu(mbOS)

for item in ['Unix', 'Linux', 'Soloris', 'Windows']:
    mbOS.menu.add_checkbutton(label=item)

mbOS['menu'] = mbOS.menu
mbOS.pack(side=LEFT)

mbLinux = Menubutton(root, text='Linux')
mbLinux.menu = Menu(mbLinux)

for item in ['Redhat', 'Fedra', 'Suse', 'Ubuntu', 'Debian']:
    mbLinux.menu.add_radiobutton(label=item)

mbLinux['menu'] = mbLinux.menu
mbLinux.pack(side=LEFT)

mbLang.menu.add_separator()
mbLang.menu.add_command(label='Rub')

mbOS.menu.insert_separator(2)
mbOS.menu.insert_checkout(3, label='FreeBSD')
mbOS.menu.insert_separator(4)

mbLinux.menu.delete(5)

root.mainloop()
